package com.daichi.controller.base;

import com.daichi.shiro.AccountProfile;
import org.apache.shiro.SecurityUtils;

public abstract class BaseController {

    public AccountProfile getProfile() {
        return (AccountProfile) SecurityUtils.getSubject().getPrincipal();
    }

    public Long getProfileId(){
        return getProfile().getId();
    }

}
